package com.lengxf.aPlugins.bizType.model;

import com.lengxf.aPlugins.bizType.BizInterface;
import com.lengxf.aPlugins.bizType.GroupSubTypeEnum;
import com.lengxf.aPlugins.bizType.GroupTypeEnum;
import com.lengxf.aPlugins.bizType.InteractionModel;

import java.util.List;

/**
 * 开工队列逻辑
 */
public class KaiGong implements BizInterface {

    @Override
    public List<InteractionModel> getInteractionModelList() {
        return List.of(
                responseInteractionModel(),
                requestInteractionModel(),
                dataInteractionModel()
        );
    }

    public static InteractionModel requestInteractionModel() {
        List<String> list = List.of("Req_ID1");
        return new InteractionModel(GroupTypeEnum.SUBSCRIPTION, GroupSubTypeEnum.REQUEST, list);
    }

    public static InteractionModel responseInteractionModel() {
        List<String> list = List.of("Rsp_ID1");
        return new InteractionModel(GroupTypeEnum.WRITE, GroupSubTypeEnum.COMPLETE, list);
    }

    public static InteractionModel dataInteractionModel() {
        List<String> list = List.of(
                "VIN1",  //01下载:VIN/(String[17])
                "MateriaType1", //02下载:白车身物料号(String[17])
                "BodyType1", //03下载:主车型
                "Config01", //04下载:发舱配置
                "Config02", //05下载:下部配置
                "Config03", //06下载:主焊1线配置
                "Config04", //07下载:主焊2线配置
                "Config05", //08下载:左侧围配置
                "Config06", //09下载:右侧围配置
                "Config07", //10下载:顶盖配置
                "Config08", //11下载:侧围轮罩配置
                "Config09", //12下载:后地板配置
                "Config10", //13下载:动力配置
                "Config11", //14下载:ER20配置
                "Flag", //47下载:上下线标志
                "Spare1", //48下载:Spare
                "BodyNo1" //49下载:车身号
//                "BodyState", //50下载:车辆状态
//                "Skid1" //51下载:载具编号
        );
        return new InteractionModel(GroupTypeEnum.WRITE, GroupSubTypeEnum.WRITE, list);
    }

}
